//
//  NDRefreshControlContainViewDelegate.h
//  JiMeiUnv
//
//  Created by devp on 14-9-18.
//  Copyright (c) 2014年 nd. All rights reserved.
//

@class NDRefreshControl;

typedef NS_ENUM(NSInteger, NDCircleContentViewState) {
    NDCircleContentViewStateUnknow,     // 未知状态
    NDCircleContentViewStateLoading,    // 加载中
    NDCircleContentViewStateFinish      // 加载结束
};

typedef NS_ENUM(NSInteger, NDRefreshLoadMoreFlag) {
    NDRefreshLoadMoreNormal,        // 正常
    NDRefreshLoadMoreNoMore         // 没有更多数据
};

@protocol NDRefreshControlContainViewDelegate <NSObject>

@optional
/**
 *    刷新控件所在scrollview被拖动回调
 *
 *    @param refreshControl 刷新控件
 *    @param offset         被拖动的偏移量
 *    @param progress       被拖动的偏移量与阈值比例
 */
- (void)nd_refreshControl:(NDRefreshControl *)refreshControl scrollViewDraggedOffset:(CGFloat)offset progress:(CGFloat)progress;
/**
 *    刷新控件是否可以被
 *
 *    @param refreshControl 刷新控件
 *
 *    @return 返回YES代表刷新控件可以被触发刷新动作，否则返回NO
 */
- (BOOL)nd_refreshControlCanTriggered:(NDRefreshControl *)refreshControl;
/**
 *    刷新控件即将触发刷新动作
 *
 *    @param refreshControl 刷新控件
 */
- (void)nd_refreshControlWillTriggerRefresh:(NDRefreshControl *)refreshControl;
/**
 *    刷新控件即将完成刷新动作
 *
 *    @param refreshControl 刷新控件
 */
- (void)nd_refreshControlWillFinishRefresh:(NDRefreshControl *)refreshControl;
@end